﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.ComponentModel.DataAnnotations;
using System.Linq;
using System.Web;

namespace FacialClub.Models.Entities
{
    /// <summary>
    /// Account
    /// </summary>
    public class Account
    {
        /// <summary>
        /// Change Password Model
        /// </summary>
        [PropertiesMustMatch("NewPassword", "ConfirmPassword",ErrorMessage = "The new password and confirmation password do not match.")]
        public class ChangePasswordModel
        {
            /// <summary>
            /// Old Password
            /// </summary>
            [Required]
            [DataType(DataType.Password)]
            [DisplayName("Current password")]
            public string OldPassword { get; set; }

            /// <summary>
            /// New Password
            /// </summary>
            [Required]
            [ValidatePasswordLength]
            [DataType(DataType.Password)]
            [DisplayName("New password")]
            public string NewPassword { get; set; }

            /// <summary>
            /// Confirm Password
            /// </summary>
            [Required]
            [DataType(DataType.Password)]
            [DisplayName("Confirm new password")]
            public string ConfirmPassword { get; set; }
        }

        /// <summary>
        /// LogOnModel
        /// </summary>
        public class LogOnModel
        {
            /// <summary>
            /// UserName
            /// </summary>
            [Required]
            [DisplayName("User name")]
            public string UserName { get; set; }

            /// <summary>
            /// Password
            /// </summary>
            [Required]
            [DataType(DataType.Password)]
            [DisplayName("Password")]
            public string Password { get; set; }

            /// <summary>
            /// Remember Me 
            /// </summary>
            [DisplayName("Remember me?")]
            public bool RememberMe { get; set; }
        }

        /// <summary>
        /// Register Model
        /// </summary>
        [PropertiesMustMatch("Password", "ConfirmPassword",ErrorMessage = "The password and confirmation password do not match.")]
        public class RegisterModel
        {
            /// <summary>
            /// UserName
            /// </summary>
            [Required]
            [DisplayName("User name")]
            public string UserName { get; set; }

            /// <summary>
            /// Email
            /// </summary>
            [Required]
            [DataType(DataType.EmailAddress)]
            [DisplayName("Email address")]
            public string Email { get; set; }

            /// <summary>
            /// Password
            /// </summary>
            [Required]
            [ValidatePasswordLength]
            [DataType(DataType.Password)]
            [DisplayName("Password")]
            public string Password { get; set; }

            /// <summary>
            /// Confirm Password
            /// </summary>
            [Required]
            [DataType(DataType.Password)]
            [DisplayName("Confirm password")]
            public string ConfirmPassword { get; set; }
        }

    }
}